<html>
<head>
    <meta charset="utf8"/>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta content="width=device-width,user-scalable=no,initial-scale=1.0" name="viewport"/>
    <meta name="-webkit-tap-highlight" content="no"/>
    <title>测试sun模块开发</title>
    <script type="text/javascript" src="../../../test/unit/qunit.js"></script>
    <script type="text/javascript" src="../../Qmik.all.js"></script>
    <script type="text/javascript" src="./config.js"></script>
    <style type="text/css">
        #result {
            position: fixed;
            right: 0;
            top: 0;
            width: 40%;
            height: 100%;
            background: #cfcfcf;
            padding: 3px;
            overflow-y: scroll;
        }
    </style>
</head>
<body>
<div>
	<pre>
		$.config({debug:true});
		$.sun.config({
			alias:{
				"demo/Demo1":'${url}/demo1.js',
				"demo/Demo2":'${url}/demo2.js',
				"demo/Demo3":'${url}/demo3.js',
				"demo/Demo4":'${url}/demo4.js',
				"demo/Common":'${url}/common.js',
			},
			vars:{
				url:function(){
					return location.href.replace(/\/[^\/]*$/,"");
				}
			}

		});
		$.use("demo/Demo1",function(Demo1){
			Demo1.doing("..............demo1");
		});
	</pre>
    <h3>执行结果</h3>

    <div id="result">

    </div>
</div>
<script type="text/javascript">
    console.log("\r\n\r\n-=-=-sun=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-start")
    $.sun.config({
        alias:{
            "a":"a.js"
        },
        preload:[]
    })
    var result = $("#result");
    $.use("demo/Demo1", function (Demo1) {
        Demo1.doing("..............demo1 trigger");
        console.log("use demo1 ok");
    });

</script>
</body>
</html>